import request from '@/utils/request'

export function getGroup() {
    return request({
        url: `/survey_group/`,
        method: 'get',
    })
}

export function getGroupById(id) {
    return request({
        url: `/survey_group/${id}/`,
        method: 'get',
    })
}

export function editGroup(id,data) {
    return request({
        url: `/survey_group/${id}/`,
        method: 'get',
        data
    })
}


export function delGroup(id) {
    return request({
        url: `/survey_group/${id}/`,
        method: 'delete',
    })
}


export function addGroup(data) {
    return request({
        url: `/survey_group/`,
        method: 'post',
        data
    })
}

export function setSurvey(id,data) {
    return request({
        url: `/survey_group/${id}/set_survey/`,
        method: 'post',
        data
    })
}

